<template>
  <div>
    <van-tabbar v-model="active" @change="onChange">
  <van-tabbar-item icon="home-o">首页</van-tabbar-item>
  <van-tabbar-item icon="search">行测</van-tabbar-item>
  <van-tabbar-item icon="friends-o">申论</van-tabbar-item>
  <van-tabbar-item icon="setting-o">求职</van-tabbar-item>
</van-tabbar>
  </div>
</template>

<script setup lang="ts">
import { ref } from 'vue';
import { showToast } from 'vant';
 const active = ref(0);
    const onChange = (index:number) =>{
         showToast(`标签 ${index}`);
         console.log(index)
    }

</script>

<style scoped>
</style>
